package com.amit.struts;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.validator.DynaValidatorForm;

public class RegisterAction  extends Action
{
	
	@Override
	public ActionForward execute(ActionMapping mapping, ActionForm form,
			HttpServletRequest request, HttpServletResponse response)
			throws Exception {
		
	System.out.println("**execute() of Registeration Action**");
	DynaValidatorForm dvf=(DynaValidatorForm) form;
	
	String un=dvf.get("uname").toString();
	String age=dvf.get("age").toString();
	String em=dvf.get("email").toString();
	String dob=dvf.get("dob").toString();
	String dor=dvf.get("dor").toString();
	String fee=dvf.get("fee").toString();
	
	System.out.println(un);
	System.out.println(age);
	System.out.println(em);
	System.out.println(dob);
	System.out.println(dor);
	System.out.println(fee);
	
		
		return mapping.findForward("success");
	}
	

}
